import request from '@/utils/request'

// 查询生产单元类型列表
export function listWorkCellType(query) {
  return request({
    url: '/yyj/pbs/workCellType/list',
    method: 'get',
    params: query
  })
}

export function allWorkCellType(query) {
  return request({
    url: '/yyj/pbs/workCellType/all',
    method: 'get',
    params: query
  })
}

// 查询生产单元类型详细
export function getWorkCellType(workCtCode) {
  return request({
    url: '/yyj/pbs/workCellType/' + workCtCode,
    method: 'get'
  })
}

// 新增生产单元类型
export function addWorkCellType(data) {
  return request({
    url: '/yyj/pbs/workCellType',
    method: 'post',
    data: data
  })
}

// 修改生产单元类型
export function updateWorkCellType(data) {
  return request({
    url: '/yyj/pbs/workCellType',
    method: 'put',
    data: data
  })
}

// 删除生产单元类型
export function delWorkCellType(workCtCode) {
  return request({
    url: '/yyj/pbs/workCellType/' + workCtCode,
    method: 'delete'
  })
}
